package com.ylbh.modules.version.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ylbh.common.pojo.version.dto.AddAppVersionDTO;
import com.ylbh.common.pojo.version.dto.AppVersionDTO;
import com.ylbh.common.pojo.version.vo.VersionVO;
import com.ylbh.modules.version.entity.ShoppingAndroidApp;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 
 * app版本控制
 * @author czx
 * @date 2019-04-29 14:46:58
 */
@Mapper
@Repository
public interface ShoppingAndroidAppMapper extends BaseMapper<ShoppingAndroidApp> {

    /**
     * 获取app版本控制列表信息
     * @param appVersionDTO
     * @return
     */
    List<ShoppingAndroidApp> selectVersionList(@Param(value = "appVersionDTO")AppVersionDTO appVersionDTO, Page page);

    /**
     * 获取app版本控制详情信息
     * @param id
     * @return
     */
    ShoppingAndroidApp selectVersionById(@Param(value = "id")Long id);

    /**
     * 获取新的版本号
     * @param appType
     */
    VersionVO selectVersionByAppType(@Param(value = "appType")Long appType);

    /**
     * 新增对应的app版本信息
     * @param addAppVersionDTO
     */
    void insertAppVersion(@Param(value = "addAppVersionDTO")AddAppVersionDTO addAppVersionDTO);
}
